﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Gota.Common.Annotations
{
    [Serializable]
    public class LabelInfo
    {
        private List<string> contents;
        public string Name { get; set; }

        public List<string> Contents
        {
            get
            {
                if (contents == null)
                {
                    contents = new List<string>();
                }
                return contents;
            }
        }

        public override string ToString()
        {
            StringBuilder sb = new StringBuilder(String.Concat(Name, " : "));
            for (int i = 0; i < Contents.Count; i++)
            {
                sb.Append(contents[i]);
                if (i < Contents.Count - 1)
                {
                    sb.Append(", ");
                }
            }
            return sb.ToString();
        }

    }
}
